:usage - install.bat, or install.bat http://webapp http://webapp/blogsite

@echo off
setlocal
if "%1" == "" goto UrlPrompt
if "%2" == "" goto UrlPrompt
set webappurl=%1
set blogsiteurl=%2
goto Main

:UrlPrompt
echo Enter URL of the blog site's web application (e.g., http://blogs):
set /p webappurl=
echo.
echo Enter the relative URL of the blog site in the web application (e.g., /myblog):
set /p blogsiteurl=
set blogsiteurl=%webappurl%%blogsiteurl%

:Main
set stsadm="%programfiles%\common files\microsoft shared\web server extensions\12\bin\stsadm.exe"

echo Deploying solution to %blogsiteurl%
@echo on

%stsadm% -o addsolution -filename CKS.EBE.wsp 
%stsadm% -o deploysolution -name CKS.EBE.wsp -allowGACDeployment -force -immediate
%stsadm% -o execadmsvcjobs
%stsadm% -o copyappbincontent
iisreset

%stsadm% -o activatefeature -filename "CKS EBE WebApp\feature.xml" -url "%webappurl%" -force

%stsadm% -o activatefeature -filename "CKS EBE\feature.xml" -url "%blogsiteurl%" -force

:End
@pause